
CFLAGS += -Wall -Werror
CPPFLAGS += -MMD
DESTDIR=/usr/bin
MANDIR=/usr/share/man/man1

all : jpegapp jpegapp.1.gz

install: jpegapp jpegapp.1.gz
	install -D -o root -g root jpegapp $(DESTDIR)/
	install -D -o root -g root jpegapp.1.gz $(MANDIR)/

clean:
	rm -f *.o *.d *~ jpegapp jpegapp.1.gz

%.1.gz: %.1
	gzip -9 < $< > $@

include $(wildcard *.d)

